#install bundler
if ! gem list | grep bundler > /dev/null; then 
	sudo gem install bundler
fi

#update dianping private repos

if [ "$1"  = "clean" ]
then 
	rm -rf iphone-graph.xcworkspace
	rm -rf iphone-graph.xcodeproj/xcuserdata
	rm -rf Pods/
    rm -rf Podfile.lock
fi

if [ -d DerivedData ]
	then
		rm -rf DerivedData/
fi

export COCOAPODS_DISABLE_DETERMINISTIC_UUIDS=YES

#bundle exec pod update
pod install --verbose --no-repo-update








